require "mysql"

my = Mysql::new("localhost", "root", "password", "myphone")
klug_contacts=my.query("select * from kanchilug")


klug_contacts.each do |contact|


system("echo    'Hi Klug,Here after KanchiLug class intimation &event information will be informed to u via sms by Bala Krishnan.pl save his no 9751897135'   | gnokii --sendsms  '#{contact[2]}' ")

print "Kanchilug msg sent to  #{contact[0]}  :  #{contact[1]}   :   #{contact[2]} \n "
sleep(10)

end

my.close
print " Msg Sent To All Kanchi Lug Members Successfully \n"
print "Bye\n"

